﻿@{
    ViewBag.Title = "t18";
}
<input type="button" value="submit" onclick='a();' />
<script language="javascript">
    function a() {
        //        alert("1");
        $.ajax(
    {
        type: "GET",
        url: "/test/t20",
        data: "id=1",
        dataType: "json",
        beforeSend: function () { },
        success: function (data) {
            alert(data.length);
            //            alert(data.items);
            //            $("#content").html(data);
            $.each(data, function (i, content) {
                //alert(content.name);
                $("#content").html(content.name);
            });
        }
    }
    )
    }
</script>
<div id="content">
    1</div>
